﻿//using Microsoft.AspNetCore.Mvc.Filters;

//using System.Diagnostics;


//internal class ApiActionFilter : IAsyncActionFilter
//{
//    private readonly ILogger<ApiActionFilter> _logger;
//    public ApiActionFilter(ILogger<ApiActionFilter> logger)
//    {
//        _logger = logger;
//    }
//    public async Task OnActionExecutionAsync(ActionExecutingContext context, ActionExecutionDelegate next)
//    {
//        Stopwatch stopwatch = Stopwatch.StartNew();
//        await next();
//        _logger.LogInformation(context.ActionDescriptor.DisplayName?.Replace("OpenPms.Controllers.","").Replace("(OpenPms)","") + stopwatch.ElapsedMilliseconds);
//    }

//}
